package com.mlh.aop;
import org.aspectj.lang.JoinPoint;
import org.aspectj.lang.Signature;
import org.aspectj.lang.annotation.Aspect;
import org.aspectj.lang.annotation.Before;
import org.springframework.stereotype.Component;

@Component
@Aspect
public class SmartAnimalAspect {
    @Before(value="execution(public void com.mlh.aop.Phone.work())")
    public void showBeginLog(JoinPoint joinPoint){
        System.out.println("前置通知");
        Signature signature = joinPoint.getSignature();
        System.out.println("日志--方法名：" + signature.getName());
    }

}
